<template>
    <div>
        <el-form :model="ruleForm" 
        status-icon :rules="rules" 
        ref="ruleForm" 
        label-width="100px" 
        class="demo-ruleForm">
            <el-form-item label="手机号码" prop="name">
                <el-input v-model="ruleForm.name" placeholder="请输入手机号"></el-input>
            </el-form-item>
             <el-form-item label="验证码" prop="captcha" class="mycaptcha">
                <el-input  type="text" v-model="ruleForm.captcha"></el-input>
                <el-button type="success">发送验证码</el-button>
            </el-form-item>
            <el-form-item>
                <el-button type="primary" class="login-sub" style="background:#892700">登录</el-button>
            </el-form-item>
        </el-form>
    </div>
</template>
<script>
  export default {
    data() {
      return {
        ruleForm: {
            name:"",
            input:"",
            captcha:""
        },
        rules: {
            name:[
                { required: true, message: '请输入手机号码', trigger: 'blur' },
                
            ],
            code:[
                { required: true, message: '请输入验证码', trigger: 'blur' },
                
            ],
        }
      };
    },
   
  }
</script>

<style lang="scss" scoped>
    .demo-ruleForm{
        width: 350px;
        margin-top: 25px;
        text-align: center;
       
    }
    .code{
        width: 150px;
    }
    .login-sub{
       border: 0;
    }
    .mycaptcha{
          ::v-deep .el-form-item__content{
        display:flex;
    }
    }
</style>